using System;
using digit.Core;
using System.Data;

namespace SMS.ServiceManager
{
    public class MatchInfo
    {
        #region CONSTRUCTORS
        public MatchInfo()
        {

            this.m_matchID = Util.NULL_LONG;
            this.m_homeTeamID = Util.NULL_LONG;
            this.m_awayTeamID = Util.NULL_LONG;
            this.m_asiaHomeRate = Util.NULL_STRING;
            this.m_asiaAwayRate = Util.NULL_STRING;
            this.m_asiaRate = Util.NULL_STRING;
            this.m_upperRate = Util.NULL_STRING;
            this.m_lowerRate = Util.NULL_STRING;
            this.m_totalRate = Util.NULL_STRING;
            this.m_otherRate = Util.NULL_STRING;
            this.m_teamPicked = Util.NULL_STRING;
            this.m_finalScore = Util.NULL_STRING;
            this.m_timePlay = Util.NULL_STRING;
            this.m_datePlay = Util.NULL_DATETIME;
            this.m_position = Util.NULL_STRING;
            this.m_type = Util.NULL_BYTE;
            this.m_win = Util.NULL_BYTE;
            this.m_createdBy = Util.NULL_STRING;
            this.m_createdDate = Util.NULL_DATETIME;
            this.m_status = Util.NULL_BYTE;
        }
        public MatchInfo(long matchID, long homeTeamID, long awayTeamID, string asiaHomeRate, string asiaAwayRate, string asiaRate, string upperRate, string lowerRate, string totalRate, string otherRate, string teamPicked, string finalScore, string timePlay, DateTime datePlay, string position, byte type, byte win, string createdBy, DateTime createdDate, byte status)
        {

            this.m_matchID = matchID;
            this.m_homeTeamID = homeTeamID;
            this.m_awayTeamID = awayTeamID;
            this.m_asiaHomeRate = asiaHomeRate;
            this.m_asiaAwayRate = asiaAwayRate;
            this.m_asiaRate = asiaRate;
            this.m_upperRate = upperRate;
            this.m_lowerRate = lowerRate;
            this.m_totalRate = totalRate;
            this.m_otherRate = otherRate;
            this.m_teamPicked = teamPicked;
            this.m_finalScore = finalScore;
            this.m_timePlay = timePlay;
            this.m_datePlay = datePlay;
            this.m_position = position;
            this.m_type = type;
            this.m_win = win;
            this.m_createdBy = createdBy;
            this.m_createdDate = createdDate;
            this.m_status = status;
        }
        public MatchInfo(DataRow dRow)
        {

            this.m_matchID = (long)Util.ReplaceDBNullTo(dRow["matchID"], Util.NULL_LONG);
            this.m_homeTeamID = (long)Util.ReplaceDBNullTo(dRow["homeTeamID"], Util.NULL_LONG);
            this.m_awayTeamID = (long)Util.ReplaceDBNullTo(dRow["awayTeamID"], Util.NULL_LONG);
            this.m_asiaHomeRate = Util.ReplaceDBNullTo(dRow["asiaHomeRate"], Util.NULL_STRING).ToString();
            this.m_asiaAwayRate = Util.ReplaceDBNullTo(dRow["asiaAwayRate"], Util.NULL_STRING).ToString();
            this.m_asiaRate = Util.ReplaceDBNullTo(dRow["asiaRate"], Util.NULL_STRING).ToString();
            this.m_upperRate = Util.ReplaceDBNullTo(dRow["upperRate"], Util.NULL_STRING).ToString();
            this.m_lowerRate = Util.ReplaceDBNullTo(dRow["lowerRate"], Util.NULL_STRING).ToString();
            this.m_totalRate = Util.ReplaceDBNullTo(dRow["totalRate"], Util.NULL_STRING).ToString();
            this.m_otherRate = Util.ReplaceDBNullTo(dRow["otherRate"], Util.NULL_STRING).ToString();
            this.m_teamPicked = Util.ReplaceDBNullTo(dRow["teamPicked"], Util.NULL_STRING).ToString();
            this.m_finalScore = Util.ReplaceDBNullTo(dRow["finalScore"], Util.NULL_STRING).ToString();
            this.m_timePlay = Util.ReplaceDBNullTo(dRow["timePlay"], Util.NULL_STRING).ToString();
            this.m_datePlay = (DateTime)Util.ReplaceDBNullTo(dRow["datePlay"], Util.NULL_DATETIME);
            this.m_position = Util.ReplaceDBNullTo(dRow["position"], Util.NULL_STRING).ToString();
            this.m_type = (byte)Util.ReplaceDBNullTo(dRow["type"], Util.NULL_BYTE);
            this.m_win = (byte)Util.ReplaceDBNullTo(dRow["win"], Util.NULL_BYTE);
            this.m_createdBy = Util.ReplaceDBNullTo(dRow["createdBy"], Util.NULL_STRING).ToString();
            this.m_createdDate = (DateTime)Util.ReplaceDBNullTo(dRow["createdDate"], Util.NULL_DATETIME);
            this.m_status = (byte)Util.ReplaceDBNullTo(dRow["status"], Util.NULL_BYTE);
        }
        #endregion

        #region ATTRIBUTES
        private long m_matchID;
        private long m_homeTeamID;
        private long m_awayTeamID;
        private string m_asiaHomeRate;
        private string m_asiaAwayRate;
        private string m_asiaRate;
        private string m_upperRate;
        private string m_lowerRate;
        private string m_totalRate;
        private string m_otherRate;
        private string m_teamPicked;
        private string m_finalScore;
        private string m_timePlay;
        private DateTime m_datePlay;
        private string m_position;
        private byte m_type;
        private byte m_win;
        private string m_createdBy;
        private DateTime m_createdDate;
        private byte m_status;
        #endregion

        #region PROPERTIES
        public long MatchID
        {
            get
            {
                return this.m_matchID;
            }
            set
            {
                this.m_matchID = value;
            }
        }

        public long HomeTeamID
        {
            get
            {
                return this.m_homeTeamID;
            }
            set
            {
                this.m_homeTeamID = value;
            }
        }

        public long AwayTeamID
        {
            get
            {
                return this.m_awayTeamID;
            }
            set
            {
                this.m_awayTeamID = value;
            }
        }

        public string AsiaHomeRate
        {
            get
            {
                return this.m_asiaHomeRate;
            }
            set
            {
                this.m_asiaHomeRate = value;
            }
        }

        public string AsiaAwayRate
        {
            get
            {
                return this.m_asiaAwayRate;
            }
            set
            {
                this.m_asiaAwayRate = value;
            }
        }

        public string AsiaRate
        {
            get
            {
                return this.m_asiaRate;
            }
            set
            {
                this.m_asiaRate = value;
            }
        }

        public string UpperRate
        {
            get
            {
                return this.m_upperRate;
            }
            set
            {
                this.m_upperRate = value;
            }
        }

        public string LowerRate
        {
            get
            {
                return this.m_lowerRate;
            }
            set
            {
                this.m_lowerRate = value;
            }
        }

        public string TotalRate
        {
            get
            {
                return this.m_totalRate;
            }
            set
            {
                this.m_totalRate = value;
            }
        }

        public string OtherRate
        {
            get
            {
                return this.m_otherRate;
            }
            set
            {
                this.m_otherRate = value;
            }
        }

        public string TeamPicked
        {
            get
            {
                return this.m_teamPicked;
            }
            set
            {
                this.m_teamPicked = value;
            }
        }

        public string FinalScore
        {
            get
            {
                return this.m_finalScore;
            }
            set
            {
                this.m_finalScore = value;
            }
        }

        public string TimePlay
        {
            get
            {
                return this.m_timePlay;
            }
            set
            {
                this.m_timePlay = value;
            }
        }

        public DateTime DatePlay
        {
            get
            {
                return this.m_datePlay;
            }
            set
            {
                this.m_datePlay = value;
            }
        }

        public string Position
        {
            get
            {
                return this.m_position;
            }
            set
            {
                this.m_position = value;
            }
        }

        public byte Type
        {
            get
            {
                return this.m_type;
            }
            set
            {
                this.m_type = value;
            }
        }

        public byte Win
        {
            get
            {
                return this.m_win;
            }
            set
            {
                this.m_win = value;
            }
        }

        public string CreatedBy
        {
            get
            {
                return this.m_createdBy;
            }
            set
            {
                this.m_createdBy = value;
            }
        }

        public DateTime CreatedDate
        {
            get
            {
                return this.m_createdDate;
            }
            set
            {
                this.m_createdDate = value;
            }
        }

        public byte Status
        {
            get
            {
                return this.m_status;
            }
            set
            {
                this.m_status = value;
            }
        }

        #endregion

    }
}